package com.yixun.constant;

import javafx.scene.input.DataFormat;

import java.text.DateFormat;
import java.text.SimpleDateFormat;

/**
 * @Author: yx
 * @Desc: 系统常量
 * @Date: 10:23 2021/4/6
 **/
public class SystemConstant {

    public static final DateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");

    /**
     * @Desc: kafka主题-站点原数据
     **/
    public static final String SITE_DATA_TOPIC = "site_data";

    /**
     * @Desc: kafka消费者组-消费原数据判断是否超过12个通道数据为空
     **/
    public static final String THAN_NULL_CONSUMER = "than_null_consumer";

    /**
     * @Desc: kafka主题-存储完成主题，升温过快故障分析
     **/
    public static final String STORAGE_COMPLETE_DATA_TOPIC = "storage_complete_data";

    /**
     * @Desc: kafka消费者主-消费存储完成主题，升温过快故障分析
     **/
    public static final String HEAT_UP_CONSUMER = "heat_up_consumer";

    /**
     * @Desc: 站点原数据redis key
     **/
    public static final String SITE_DATA_KEY = "device:%s_all";

    /**
     * @Desc: 站点通道升温过快故障 redis key      这几个都用于main程序来消费
     * breakdown:{site_no}_{aisle_no}_HEAT_UP
     **/
    public static final String BREAKDOWN_HEAT_UP_KEY = "breakdown:%s_%s_HEAT_UP";

    /**
     * @Desc: 站点超过12个通道空数据故障 redis key
     **/
    public static final String BREAKDOWN_THAN_NULL_KEY = "breakdown:%s_THAN_NULL";

    /**
     * @Desc: 站点通道连续20条数据都为空故障
     **/
    public static final String BREAKDOWN_CONTINUOUS_NULL_KEY = "breakdown:%s_%s_CONTINUOUS_NULL";

    /**
     * @Desc: redis全局唯一uid,获取 redis key
     **/
    public static final String BREAKDOWN_UID = "breakdown_uid";

    /**
     * @Desc: kafka主题：故障信息
     **/
    public static final String BREAKDOWN_TOPIC = "breakdown_data";

    /**
     * @Desc: redis key 所有站点
     **/
    public static final String ALL_SITE_KEY = "all_site_device";

}
